<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>文本围绕鼠标旋转</title>
<style>
.spanstyle
{
  position:absolute;visibility:visible;
  top:50px;
  font-size:10pt;
  font-family:Verdana;
  color:#ff0000;
}
</style>
</head>

<body>
<script language="JavaScript">
<!--
var number=6;
var step=5;
var radius=50;
var x,y;
var timer;
var pi=Math.PI;
function round()
{
  hudusu=step;
  for (i=1;i<=number;i++)
  {
	var thisspan;
	thisspan=eval("document.all.span"+(i)+".style;");
	thisspan.posLeft=radius*Math.cos(hudusu*pi/180)+x;
	thisspan.posTop=radius*Math.sin(hudusu*pi/180)+y;
	hudusu=hudusu+360/number;
　 }
  step=step+5;
  timer=setTimeout("round()",50);
}
 
function mouseMove()
{
  clearTimeout(timer);
  x=event.clientX;
  y=event.clientY;
  round();
}
document.onmousemove=mouseMove;
  
for (i=1;i<=number;i++)
{
  document.write("<span id='span"+(i)+"' class='spanstyle'>");
  document.write("☆");
  document.write("</span>");
}
-->
</script>

</body>
</html>
